﻿@* Ui层项目 - 列表组件文件 *@
@using Util.Generators.Helpers
@model Util.Generators.Contexts.EntityContext
@{
    var service = new GenerateService( Model );
    var description = $"{Model.Description}列表页";
}
import { Component,ChangeDetectionStrategy, Injector } from '@@angular/core';
import { environment } from "@@env/environment";
import { TableQueryComponentBase } from "util-angular";
import { @service.GetClientQueryClassName() } from './model/@service.GetClientQueryFileName()';
import { @service.GetClientViewModelClassName() } from './model/@service.GetClientViewModelFileName()';
import { @service.GetClientEditClassName() } from './@service.GetClientEditFileName()';
import { @service.GetClientDetailClassName() } from './@service.GetClientDetailFileName()';

/**
* @description
*/
@@Component( {
    selector: '@service.GetClientEntityFileName()-list',
    changeDetection: ChangeDetectionStrategy.OnPush,
    templateUrl: environment.production ? './html/index.component.html' : '@service.GetClientViewTemplateUrl()',
} )
export class @service.GetClientListClassName() extends TableQueryComponentBase<@service.GetClientViewModelClassName(), @service.GetClientQueryClassName()> {
    /**
     * 初始化@(description)
     * @@param injector 注入器
     */
    constructor( injector: Injector ) {
        super( injector );
    }

    /**
     * 获取创建组件
     */
    getCreateComponent() {
        return @service.GetClientEditClassName();
    }

    /**
     * 获取详情组件
     */
    getDetailComponent() {
        return @service.GetClientDetailClassName();
    }
    
    /**
     * 获取创建标题
     */
    getCreateTitle() {
        return '@service.GetCreateEntityI18nKey()';
    }

    /**
     * 获取更新标题
     */
    getEditTitle() {
        return '@service.GetUpdateEntityI18nKey()';
    }
        
    /**
     * 获取详情标题
     */
    getDetailTitle() {
        return '@service.GetEntityDetailI18nKey()';
    }
}